package thread;

public class InputThread extends Thread{
	Bank bank;

	public InputThread(Bank bank) {
		this.bank = bank;
	}

	@Override
	public void run(){
		synchronized(bank){
			for(int i=1;i<=100; i++){
				System.out.print("입금처리중");
				if(i%10==0)
					System.out.println();
			}
			bank.input(100);
			System.out.println("입금완료!(잔액:"+bank.money+")");
		}
	}
}
